﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using Googler.BLL;

namespace HodhodNews.Storage
{
    public abstract class StorageProvider
    {
        public abstract void Save(List<News> list);
        public abstract bool Create(News entry);
        public abstract void Update(News entry);
        public abstract News GetById(int oid);
        public abstract List<News> GetAll();
        public abstract List<News> GetDayNews(DateTime dt);
        public abstract List<News> GetDayNews(DateTime dt, Guid userId);
        public abstract List<News> GetDayNews(DateTime dt,int keywordId);
        public abstract List<News> GetNews(DateTime from, DateTime to);
        public abstract void UpdateStatistics();

        public static StorageProvider Insance
        {
            get
            {
               return new EntityFrameworkStorageProvider();
               // return new SqlServerStorageProvider();
            }
        }
    }
}
